package com.itheima.homework.Two;


import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

/*
* 需求：键盘录入5个学生的信息（姓名、语文成绩、数学成绩、英语成绩），按照总成绩高低输出打印各个学生的数据
* */
public class Demo {
    public static void main(String[] args) {

        Scanner scanner = new Scanner(System.in);
        List<Student> list = new ArrayList<>();
        for (int i = 0; i < 3; i++) {
            Student stu = new Student();
            stu.setName(scanner.next());
            stu.setChi(scanner.nextInt());
            stu.setEng(scanner.nextInt());
            stu.setMath(scanner.nextInt());

            list.add(stu);
        }

        System.out.println(list);


    }
}
